<?php
    // +----------------------------------------------------------------------
    // |
    // +----------------------------------------------------------------------
    // | Copyright (c) 2016~2030 http://www.jmzh1688.com All rights reserved.
    // +----------------------------------------------------------------------
    // | Licensed ( http://www.jmzh1688.com/licenses/LICENSE-2.0 )
    // +----------------------------------------------------------------------
    // | Author: lxl
    // | jmzhfsauto
    // +----------------------------------------------------------------------
    namespace app\document\controller;
    use think\Controller;
    use think\Db;
    class Database extends Controller {
        private function readhtmlfile($jsonfile) {
            if (file_exists($jsonfile)) {
                $json_string = file_get_contents($jsonfile);
                return $json_string;
            } else {
                return "";
            }
        }
        public function index() {
            $content = $this->readhtmlfile("mobancode/code.txt");
            $this->assign(['mobancode'=>$content]);
            return $this->fetch();
        }
    }
    